/*
 * Created by SharpDevelop.
 * User: tentus
 * Date: 2006-10-27
 * Time: 02:50
 * 
 * To change this template use Tools | Options | Coding | Edit Standard Headers.
 */

using System;
using System.Drawing;
using System.Windows.Forms;
using System.Collections.Generic;

namespace ActionManager
{
	/// <summary>
	/// Description of ActionComboList.
	/// </summary>
	public partial class ActionComboList
	{
		public ActionComboList()
		{
			//
			// The InitializeComponent() call is required for Windows Forms designer support.
			//
			InitializeComponent();						
		}
		
		public int ShowComboList(List<string> _list)
		{
			comboBox1.Items.Clear();
			
			for (int i=0; i<_list.Count; ++i)
				comboBox1.Items.Add(_list[i]);
			
			if (ShowDialog()==DialogResult.OK)
				return comboBox1.SelectedIndex;;
			
			return -1;	
		}
	}
}
